www.gusucode.com > 智睿学校网站管理系统 V2.20 > 智睿学校网站管理系统 V2.20\code\UserList.asp
<!--#include file="Include/conn.asp"--> <!--#include file="Include/Fun_SqlIn.Asp"--> <!--#include file="Include/Inc_Page.asp"--> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <meta http-equiv="Content-Type" content="text/html; charset=GB2312" /> <meta http-equiv="Content-Language" content="zh-CN" /> <title>会员中心 - <%=SiteTitle%></title> <meta name="keywords" content="<%=Sitekeywords%>" /> <meta name="description" content="<%=Sitedescription%>" /> <link href="images/style.css" rel="stylesheet" type="text/css" /> <script language="javascript" src="images/zhirui.js"></script> </head> <body> <%head()%> <table width="950" border="0" align="center" cellpadding="0" cellspacing="0" class="main_class"> <tr> <td width="240" valign="top" class="leftCenter" > <!--#include file="Include/login.asp"--> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td class="Ma_left">关于我们</td> </tr> <tr> <td align="left"><div style="margin-left:10px;"><% =WebMenu()%></div></td> </tr> </table> <br> </td> <td width="5"></td> <td valign="top"class="viewright"> <% dim UserName,UserID UserName=session("zhi_rui_s_MemName") UserID=session("zhi_rui_s_userID") If UserName="" then Response.Redirect "UserLogin.asp" Response.End() end if %> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td height="25" style="border-bottom:solid 1px; margin-top:5px;" > <span class="note">您的作品<font color=red><b><%=Mydb("Select Count([ID]) From [zhi_rui_s_po] Where UserID="&UserID,1)(0)%></b></font> 篇 | 未审核 <font color=red><b><%=Mydb("Select Count([ID]) From [zhi_rui_s_po] Where ViewFlag=0 and UserID="&UserID,1)(0)%></b></font> 篇</span><a href="UserPi.asp"></a> </td> </tr> </table> <% if request("action")="del" then call del() elseif request("action")="delAll" then call delAll() else call List() end if sub List() dim page page=request("page") %> <form name="myform" method="POST" action="?action=delAll"> <table width="99%" border="0" align=center cellpadding="0" cellspacing="1" bgcolor="#FFFFFF" style="border:solid 1px EEE; margin-top:10px;"> <tr bgcolor="#EBF2F9" style="font-weight:bold;"> <td align="center">序号</td> <td align="center">作品名称</td> <td align="center">图片管理</td> <td width="20%" height="30" align="center">发布时间</td> <td height="30" align="center">浏览</td> <td height="30" align="center">管理</td> </tr> <% Set mypage=new xdownpage mypage.getconn=conn sql="select * from zhi_rui_s_po where UserID="&UserID&" order by id desc" mypage.getsql=sql mypage.pagesize=15 set rs=mypage.getrs() for i=1 to mypage.pagesize if not rs.eof then %> <tr bgcolor="#F8FBFE" onMouseOver="this.style.backgroundColor='#FAF5EC';this.style.color='red'" onMouseOut="this.style.backgroundColor='';this.style.color=''"> <td align="center" style="padding:5px 0px 0px 10px;"><%=rs("ID")%></td> <td align="center"><%=rs("PhotoName")%></td> <td align='center'><input type='button' class='but1' value='添加更多图片' onClick="window.location='UserPo.asp?poid=<%=rs("id")%>&Result=Add&poname=<%=rs("PhotoName")%>'"></td> <td align="center"><%=rs("AddTime")%></td> <td align="center"><%=rs("Hits")%></td> <td align="center"><%If rs("ViewFlag")=1 then Response.Write("已审") end if:If rs("ViewFlag")=0 then Response.Write("<font color=red>未审</font>") end if%>|<a href="UserAdd.asp?Result=Modify&ID=<%=rs("ID")%>">编辑</a></td> </tr> <% rs.movenext else exit for end if next %> <tr style="display:none;"> <td align="center" bgcolor="EBF2F9"><input name="Action" type="hidden" value="Del"><input name="chkAll" type="checkbox" id="chkAll" onClick=CheckAll(this.form) value="checkbox" style="border:0"></td> <td colspan="5" align="left" bgcolor="EBF2F9"><input name="Del" type="submit" class="but1" id="Del" value="删除"></td> </tr> <tr> <td bgcolor="EBF2F9" colspan="6" height="30" align="right" ><%=mypage.showpage()%></td> </tr> </table> </form> <% end sub sub del() id=request("id") set rs=conn.execute("delete from zhi_rui_s_po where UserID="&UserID&" and id="&id) Response.write"<script>alert(""删除成功!"");location.href=""?action=list"";</script>" end sub Sub delAll ID=Trim(Request("ID")) ytype=Request("ytype") If ID="" Then Response.Write("<script language=javascript>alert('请选择作品!');history.back(1);</script>") Response.End ElseIf Request("Del")="删除" Then set rs=conn.execute("delete from zhi_rui_s_po where ID In(" & ID & ")") Response.write"<script>alert(""删除成功!"");location.href=""?action=list"";</script>" End If End Sub %> </td> </tr> </table> <%Bottom()%> </body> </html>